<?php

namespace App\Models;


use Illuminate\Database\Eloquent\Model;

class AnswerSurveyLog extends Model
{
	
    protected $table = 'answer_survey_logs';

    protected $fillable = [
        'user_id',
        'answer_id',
        'subject_id',
        'option_id',
        'score',
        'content'
    ];

    public function answer()
    {
        return $this->belongsTo(AnswerSurvey::class);
    }

    public function subject()
    {
        return $this->belongsTo(AnswerSurveySubject::class);
    }

    public function option()
    {
        return $this->belongsTo(AnswerSurveyOption::class);
    }

    public function user()
    {
        return $this->belongsTo(User::class);
    }
}
